{
 "cells": [
  {
   "cell_type": "code",
   "execution_count": 2,
   "id": "9c3782a6-dff8-436f-b93f-dfab53ba845a",
   "metadata": {},
   "outputs": [],
   "source": [
    "import numpy as np\n",
    "import pandas as pd"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 2,
   "id": "e1e45b8b-7547-4dfe-9e37-d22b9d2f2e96",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "'2.2.3'"
      ]
     },
     "execution_count": 2,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "pd.__version__"
   ]
  },
  {
   "cell_type": "markdown",
   "id": "6357d5a9-e91d-48b8-92ba-6db658da8fc7",
   "metadata": {},
   "source": [
    "# 读取CSV txt xlsx\n",
    "## 读取后的 df_csv 是一个Dataframe 对象"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 3,
   "id": "1f921e63-057a-47d7-89c4-d57fc20f430a",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>col1</th>\n",
       "      <th>col2</th>\n",
       "      <th>col3</th>\n",
       "      <th>col4</th>\n",
       "      <th>col5</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>2</td>\n",
       "      <td>a</td>\n",
       "      <td>1.4</td>\n",
       "      <td>apple</td>\n",
       "      <td>2020/1/1</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>3</td>\n",
       "      <td>b</td>\n",
       "      <td>3.4</td>\n",
       "      <td>banana</td>\n",
       "      <td>2020/1/2</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>6</td>\n",
       "      <td>c</td>\n",
       "      <td>2.5</td>\n",
       "      <td>orange</td>\n",
       "      <td>2020/1/5</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>5</td>\n",
       "      <td>d</td>\n",
       "      <td>3.2</td>\n",
       "      <td>lemon</td>\n",
       "      <td>2020/1/7</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "   col1 col2  col3    col4      col5\n",
       "0     2    a   1.4   apple  2020/1/1\n",
       "1     3    b   3.4  banana  2020/1/2\n",
       "2     6    c   2.5  orange  2020/1/5\n",
       "3     5    d   3.2   lemon  2020/1/7"
      ]
     },
     "execution_count": 3,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "df_csv=pd.read_csv('data/my_csv.csv') \n",
    "df_csv"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 4,
   "id": "0a62cfcb-002b-4a38-8695-9b3980caca14",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>col1</th>\n",
       "      <th>col2</th>\n",
       "      <th>col3</th>\n",
       "      <th>col4</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>2</td>\n",
       "      <td>a</td>\n",
       "      <td>1.4</td>\n",
       "      <td>apple 2020/1/1</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>3</td>\n",
       "      <td>b</td>\n",
       "      <td>3.4</td>\n",
       "      <td>banana 2020/1/2</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>6</td>\n",
       "      <td>c</td>\n",
       "      <td>2.5</td>\n",
       "      <td>orange 2020/1/5</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>5</td>\n",
       "      <td>d</td>\n",
       "      <td>3.2</td>\n",
       "      <td>lemon 2020/1/7</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "   col1 col2  col3             col4\n",
       "0     2    a   1.4   apple 2020/1/1\n",
       "1     3    b   3.4  banana 2020/1/2\n",
       "2     6    c   2.5  orange 2020/1/5\n",
       "3     5    d   3.2   lemon 2020/1/7"
      ]
     },
     "execution_count": 4,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "df_txt=pd.read_table('data/my_table.txt')\n",
    "df_txt"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 5,
   "id": "72f28281-6ee0-437c-a97e-7fb6d93d6ef0",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>col1</th>\n",
       "      <th>col2</th>\n",
       "      <th>col3</th>\n",
       "      <th>col4</th>\n",
       "      <th>col5</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>2</td>\n",
       "      <td>a</td>\n",
       "      <td>1.4</td>\n",
       "      <td>apple</td>\n",
       "      <td>2020/1/1</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>3</td>\n",
       "      <td>b</td>\n",
       "      <td>3.4</td>\n",
       "      <td>banana</td>\n",
       "      <td>2020/1/2</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>6</td>\n",
       "      <td>c</td>\n",
       "      <td>2.5</td>\n",
       "      <td>orange</td>\n",
       "      <td>2020/1/5</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>5</td>\n",
       "      <td>d</td>\n",
       "      <td>3.2</td>\n",
       "      <td>lemon</td>\n",
       "      <td>2020/1/7</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "   col1 col2  col3    col4      col5\n",
       "0     2    a   1.4   apple  2020/1/1\n",
       "1     3    b   3.4  banana  2020/1/2\n",
       "2     6    c   2.5  orange  2020/1/5\n",
       "3     5    d   3.2   lemon  2020/1/7"
      ]
     },
     "execution_count": 5,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "df_excel=pd.read_excel('data/my_excel.xlsx')\n",
    "df_excel"
   ]
  },
  {
   "cell_type": "markdown",
   "id": "b45bdf9e-6e6c-4b40-bfb7-ba53a7546b5b",
   "metadata": {},
   "source": [
    "## 第一行不作为列名"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 6,
   "id": "7d3339c0-fb69-4b3b-86b8-b61414167ce6",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>0</th>\n",
       "      <th>1</th>\n",
       "      <th>2</th>\n",
       "      <th>3</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>col1</td>\n",
       "      <td>col2</td>\n",
       "      <td>col3</td>\n",
       "      <td>col4</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>2</td>\n",
       "      <td>a</td>\n",
       "      <td>1.4</td>\n",
       "      <td>apple 2020/1/1</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>3</td>\n",
       "      <td>b</td>\n",
       "      <td>3.4</td>\n",
       "      <td>banana 2020/1/2</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>6</td>\n",
       "      <td>c</td>\n",
       "      <td>2.5</td>\n",
       "      <td>orange 2020/1/5</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>5</td>\n",
       "      <td>d</td>\n",
       "      <td>3.2</td>\n",
       "      <td>lemon 2020/1/7</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "      0     1     2                3\n",
       "0  col1  col2  col3             col4\n",
       "1     2     a   1.4   apple 2020/1/1\n",
       "2     3     b   3.4  banana 2020/1/2\n",
       "3     6     c   2.5  orange 2020/1/5\n",
       "4     5     d   3.2   lemon 2020/1/7"
      ]
     },
     "execution_count": 6,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "pd.read_table('data/my_table.txt',header=None)"
   ]
  },
  {
   "cell_type": "markdown",
   "id": "d3611238-3b9b-4154-95e2-41ea720a20c7",
   "metadata": {},
   "source": [
    "## 把某一列 或几列，指定为索引\n",
    "### pandas中的索引，可以理解为行号。不同于mysql，它不会加速查找"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 8,
   "id": "34915d5c-2b04-4860-9139-f8bf0b17cc67",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th>col3</th>\n",
       "      <th>col4</th>\n",
       "      <th>col5</th>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>col1</th>\n",
       "      <th>col2</th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <th>a</th>\n",
       "      <td>1.4</td>\n",
       "      <td>apple</td>\n",
       "      <td>2020/1/1</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <th>b</th>\n",
       "      <td>3.4</td>\n",
       "      <td>banana</td>\n",
       "      <td>2020/1/2</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>6</th>\n",
       "      <th>c</th>\n",
       "      <td>2.5</td>\n",
       "      <td>orange</td>\n",
       "      <td>2020/1/5</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>5</th>\n",
       "      <th>d</th>\n",
       "      <td>3.2</td>\n",
       "      <td>lemon</td>\n",
       "      <td>2020/1/7</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "           col3    col4      col5\n",
       "col1 col2                        \n",
       "2    a      1.4   apple  2020/1/1\n",
       "3    b      3.4  banana  2020/1/2\n",
       "6    c      2.5  orange  2020/1/5\n",
       "5    d      3.2   lemon  2020/1/7"
      ]
     },
     "execution_count": 8,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "pd.read_csv('data/my_csv.csv',index_col=['col1','col2'])"
   ]
  },
  {
   "cell_type": "markdown",
   "id": "0fd837d8-04ea-40e2-86b9-4175afab76f3",
   "metadata": {},
   "source": [
    "## 只读取 csv 文件中的 col1 和 col2 两列，其它列会被忽略。"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 9,
   "id": "9cde4ca3-6255-4814-83a3-fe4a124fae86",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>col1</th>\n",
       "      <th>col2</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>2</td>\n",
       "      <td>a</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>3</td>\n",
       "      <td>b</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>6</td>\n",
       "      <td>c</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>5</td>\n",
       "      <td>d</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "   col1 col2\n",
       "0     2    a\n",
       "1     3    b\n",
       "2     6    c\n",
       "3     5    d"
      ]
     },
     "execution_count": 9,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "pd.read_csv('data/my_csv.csv',usecols=['col1','col2'])"
   ]
  },
  {
   "cell_type": "markdown",
   "id": "90cfbad6-1496-458c-8de4-46b0da3bf69c",
   "metadata": {},
   "source": [
    "## 限制读取的行数"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 11,
   "id": "6382ba36-f11c-4a63-aab3-f93838fb95c4",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>col1</th>\n",
       "      <th>col2</th>\n",
       "      <th>col3</th>\n",
       "      <th>col4</th>\n",
       "      <th>col5</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>2</td>\n",
       "      <td>a</td>\n",
       "      <td>1.4</td>\n",
       "      <td>apple</td>\n",
       "      <td>2020/1/1</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>3</td>\n",
       "      <td>b</td>\n",
       "      <td>3.4</td>\n",
       "      <td>banana</td>\n",
       "      <td>2020/1/2</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "   col1 col2  col3    col4      col5\n",
       "0     2    a   1.4   apple  2020/1/1\n",
       "1     3    b   3.4  banana  2020/1/2"
      ]
     },
     "execution_count": 11,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "pd.read_excel('data/my_excel.xlsx',nrows=2)"
   ]
  },
  {
   "cell_type": "markdown",
   "id": "a84a45a3-91b2-43b1-9556-e29d065c2959",
   "metadata": {},
   "source": [
    "### 在读取 txt 文件时，经常遇到分隔符非空格的情况， read_table 有一个分割参数 sep ，它使得用户可以自定义分割符号，进行 txt 数据的读取。例如，下面的读取的表以 |||| 为分割：\n",
    "### 参数 sep 中使用的是正则表达式，因此需要对 | 进行转义变成 \\| ，否则无法读取到正确的结果"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 14,
   "id": "982f0915-00f1-40d0-8027-5ce69c30390b",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>col1</th>\n",
       "      <th>col2</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>TS</td>\n",
       "      <td>This is an apple.</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>GQ</td>\n",
       "      <td>My name is Bob.</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>WT</td>\n",
       "      <td>Well done!</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>PT</td>\n",
       "      <td>May I help you?</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "  col1                 col2\n",
       "0   TS    This is an apple.\n",
       "1   GQ      My name is Bob.\n",
       "2   WT           Well done!\n",
       "3   PT      May I help you?"
      ]
     },
     "execution_count": 14,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "pd.read_table('data/my_table_special_sep.txt',sep='\\|\\|\\|\\|',engine='python')"
   ]
  },
  {
   "cell_type": "markdown",
   "id": "26027afb-5dc8-46fe-b620-5d27a9416d0c",
   "metadata": {},
   "source": [
    "# 保存\n",
    "## 常用的操作是会把index设置为False， 否则最左侧会多一列行号"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 15,
   "id": "06aab6c9-3dc6-4773-b3ba-2977625f983c",
   "metadata": {},
   "outputs": [],
   "source": [
    "df_csv.to_csv('data/jj_csv_saved.csv',index=False)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 16,
   "id": "a7eddaa9-f85b-40e0-8dd3-585661f16e30",
   "metadata": {},
   "outputs": [],
   "source": [
    "df_csv.to_csv('data/jj_csv_index_saved.csv')"
   ]
  },
  {
   "cell_type": "markdown",
   "id": "c503ad5b-97ae-4ad7-b44d-0e300fcef90f",
   "metadata": {},
   "source": [
    "## 注意，读txt时 是read_table，但保存时，还是用 to_csv"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 19,
   "id": "e8c01e43-9400-4c0c-a009-1c1e3a03b299",
   "metadata": {},
   "outputs": [],
   "source": [
    "df_txt.to_csv('data/jj_txt_saved.txt',index=False)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "id": "037dbcea-26fc-4a8b-9b11-8e53b0792d31",
   "metadata": {},
   "outputs": [],
   "source": []
  }
 ],
 "metadata": {
  "kernelspec": {
   "display_name": "Python [conda env:base] *",
   "language": "python",
   "name": "conda-base-py"
  },
  "language_info": {
   "codemirror_mode": {
    "name": "ipython",
    "version": 3
   },
   "file_extension": ".py",
   "mimetype": "text/x-python",
   "name": "python",
   "nbconvert_exporter": "python",
   "pygments_lexer": "ipython3",
   "version": "3.13.5"
  }
 },
 "nbformat": 4,
 "nbformat_minor": 5
}
